package org.jsola.hr.web;

import io.swagger.annotations.Api;
import io.swagger.annotations.ApiImplicitParam;
import io.swagger.annotations.ApiImplicitParams;
import io.swagger.annotations.ApiOperation;
import org.jsola.core.Page;
import org.jsola.core.Result;
import org.jsola.hr.dto.AttendReportAddDTO;
import org.jsola.hr.dto.AttendReportUpdateDTO;
import org.jsola.hr.query.AttendReportQuery;
import org.jsola.hr.vo.AttendReportListVO;
import org.jsola.hr.vo.AttendReportVO;

import java.util.List;

/**
 * @author zhr
 */
@Api(tags = "hr-考勤汇报对象")
public interface IAttendReportControllerAPI {

    /**
     * 新增考勤汇报对象
     * @param attendReportAddDTO 考勤汇报对象新增实体
     * @return 考勤汇报对象展示对象
     */
    @ApiOperation(value = "新增考勤汇报对象")
    @ApiImplicitParams({
            @ApiImplicitParam(name = "attendReportAddDTO", dataType = "AttendReportAddDTO", value = "新增考勤汇报对象", paramType = "body")
    })
    Result<AttendReportVO> save(AttendReportAddDTO attendReportAddDTO);


    /**
     * 修改考勤汇报对象
     * @param attendReportUpdateDTO 考勤汇报对象
     * @return 更新数量
     */
    @ApiOperation(value = "修改考勤汇报对象")
    @ApiImplicitParams({
            @ApiImplicitParam(name = "attendReportUpdateDTO", dataType = "AttendReportUpdateDTO", value = "修改考勤汇报对象", paramType = "body")
    })
    Result<Integer> update(AttendReportUpdateDTO attendReportUpdateDTO);




    /**
     * 删除单个考勤汇报对象，彻底删除
     * @param attendReportId 考勤汇报对象id
     * @return 删除数量
     */
    @ApiOperation(value="删除单个考勤汇报对象，彻底删除")
    @ApiImplicitParams({
            @ApiImplicitParam(name = "attendReportId", dataType = "String", value = "考勤汇报对象id", paramType = "path")
    })
    Result<Integer> delete(String attendReportId);


    /**
     * 批量删除考勤汇报对象，彻底删除
     * @param attendReportIds 考勤汇报对象id集合
     * @return 删除数量
     */
    @ApiOperation(value = "批量删除考勤汇报对象，彻底删除")
    @ApiImplicitParams({
            @ApiImplicitParam(name = "attendReportIds", dataType = "String[]", value = "考勤汇报对象id数组", paramType = "body" ,allowMultiple = true)
    })
    Result<Integer> deleteBatch(String[] attendReportIds);


    /**
     * 根据考勤汇报对象id查询考勤汇报对象详情
     * @param attendReportId 考勤汇报对象id
     * @return 考勤汇报对象详情
     */
    @ApiOperation(value="根据考勤汇报对象id查询考勤汇报对象详情")
    @ApiImplicitParams({
            @ApiImplicitParam(name = "attendReportId", dataType = "String", value = "考勤汇报对象id", paramType = "path")
    })
    Result<AttendReportVO> findById(String attendReportId);


    /**
     * 查询考勤汇报对象
     * @param attendReportQuery 考勤汇报对象查询参数
     * @return page
     */
    @ApiOperation(value="查询考勤汇报对象")
    @ApiImplicitParams({
            @ApiImplicitParam(name = "attendReportQuery", dataType = "AttendReportQuery", value = "考勤汇报对象查询参数", paramType = "query")
    })
    Result<List<AttendReportListVO>> listAll(AttendReportQuery attendReportQuery);


     /**
     * 分页查询考勤汇报对象
     * @param attendReportQuery 考勤汇报对象查询参数
     * @return page
     */
    @ApiOperation(value="分页查询考勤汇报对象")
    @ApiImplicitParams({
            @ApiImplicitParam(name = "attendReportQuery", dataType = "AttendReportQuery", value = "考勤汇报对象查询参数", paramType = "query")
    })
    Result<Page<AttendReportListVO>> page(AttendReportQuery attendReportQuery);


}

